#pragma once

#include "../gfx/RenderableUnit.h"
#include "../shared/shared_types.h"
#include <string>

namespace Putin{

class GameObject;

/*!
 * \brief
 * A special version of the RenderableUnit to make it syncronized with the GameObject class
 * 
 * \see
 * GameObject | RenderableUnit
 */
class RenderableUnitImpl : public RenderableUnit
{
public:

	RenderableUnitImpl(GameObject* obj) : mObj(obj)
	{}

	//Getters and setters
	 Vec3f getPosition();
     Vec3f getFacingDirection();
	 Vec3f getChildDirection();
     Vec3f getUpVector();
	 std::string getId();
	 std::string getMesh();
	 std::string getMaterial();
	 std::string getChildMesh();
	 std::string getChildMaterial();
	 bool hasChild();
	 float getScale(){return mObj->getScale();}
	 bool	isShadowcaster(){return mObj->mShadow;}
	 // Whatever
	 virtual std::vector< std::string > getParticleEffects();

	//Temporary class, will se if we can use it or remake it somehow.
	virtual void setPosition( Vec3f position );
    virtual void setFacingDirection( Vec3f facingDirection );
    virtual void setUpVector( Vec3f upVector );
	virtual void setMesh( const std::string& mesh );
	virtual void setMesh();
	virtual void setMaterial( const std::string& material );
	virtual void setId( std::string id );
	virtual void addParticleEffect( const std::string& effect );
	virtual void removeParticleEffect( const std::string& effect );
	virtual bool hasParticleEffect( void );

	virtual std::vector<std::string> getAddEffect(){return mObj->mEffectsToBeAdded; }
	virtual std::vector<std::string> getDroppedEffects(){return mObj->mEffectsToBeDropped;}
	virtual std::vector<std::string> getChildAddEffects(){return mObj->mChildEffectsToBeAdded;}
	virtual std::vector<std::string> getChildDroppedEffects(){return mObj->mChildEffectsToBeDropped;}


private:
	GameObject*	mObj;

};

}